home *** CD-ROM | disk | FTP | other *** search
/ FM Towns: Free Software Collection 9 / FM Towns Free Software Collection 9.iso / t_os / tool / otohime / src / iotpch.c < prev    next >
C/C++ Source or Header  |  1994-11-16  |  12KB  |  512 lines

  1. #include <stdio.h>
  2. #include <stdlib.h>
  3. #include <winb.h>
  4. #include <te.h>
  5. #include <fntb.h>
  6. #include <gui.h>
  7.  
  8. extern int    pitchDialogId ;
  9. extern int    pitchOkBtnId ;
  10. extern int    pitchOkchk() ;
  11. extern int    pitchPlayBtnId ;
  12. extern int    pitchPlay() ;
  13. extern int    pitchUndoBtnId ;
  14. extern int    pitchUndo() ;
  15. extern int    pitchInfBtnId ;
  16. extern int    pitchInf() ;
  17. extern int    pitchCanBtnId ;
  18. extern int    pitchCanchk() ;
  19. extern int    pitchMesId[20] ;
  20. extern int    pitchSubDialogId ;
  21. extern int    pitchMulVolumeId ;
  22. extern int    pitchMulSet() ;
  23. extern int    pitchMulNumId ;
  24.  
  25. #define ALIGN    4
  26. #define OFFSET(type) (sizeof(MMIPACKET) + (sizeof(type)+ALIGN-1)/ALIGN*ALIGN)
  27.  
  28. /*    MMI_init 用データ    */
  29.  
  30. /*    ヘッダ    */
  31.  
  32. MMIINIT    initDataIOTPCH = { "MmiInit",  29, 0 } ;
  33.  
  34. /* pitchDialogId */
  35.  
  36. static MMIPACKET d001 = {    &pitchDialogId,
  37.                             NULL,
  38.                             &MJ_DIALOGL40,
  39.                             OFFSET(DIALOGL40),
  40.                             MS_NONE
  41.                         } ;
  42. static DIALOGL40    d001d = {    MS_BTLEFTL40 | MS_EVMOSONL40,
  43.                               30, 159, 610, 322, 8, 4, 8,
  44.                             MS_SRECTL40 | MS_UFRAMEL40 | MS_FRAMEL40,
  45.                             NULL,   0,   0
  46.                         } ;
  47.  
  48. /* pitchOkBtnId */
  49.  
  50. static MMIPACKET d002 = {    &pitchOkBtnId,
  51.                             &pitchDialogId,
  52.                             &MJ_DBUTTONL40,
  53.                             OFFSET(DBUTTONL40),
  54.                             MS_NONE
  55.                         } ;
  56. static DBUTTONL40    d002d = {    MS_BTLEFTL40 | MS_EVMOSOFFL40 | MS_EVKEYONL40,
  57.                               50, 291, 111, 314,12, 4, 8,
  58.                             MS_PANELL40 | MS_FRAMEL40,
  59.                             pitchOkchk,
  60.                             0x0000
  61.                         } ;
  62.  
  63. /* pitchPlayBtnId */
  64.  
  65. static MMIPACKET d003 = {    &pitchPlayBtnId,
  66.                             &pitchDialogId,
  67.                             &MJ_DBUTTONL40,
  68.                             OFFSET(DBUTTONL40),
  69.                             MS_NONE
  70.                         } ;
  71. static DBUTTONL40    d003d = {    MS_BTLEFTL40 | MS_EVMOSOFFL40 | MS_EVKEYONL40,
  72.                              120, 291, 181, 314, 7, 4, 8,
  73.                             MS_PANELL40 | MS_FRAMEL40,
  74.                             pitchPlay,
  75.                             0x0000
  76.                         } ;
  77.  
  78. /* pitchUndoBtnId */
  79.  
  80. static MMIPACKET d004 = {    &pitchUndoBtnId,
  81.                             &pitchDialogId,
  82.                             &MJ_DBUTTONL40,
  83.                             OFFSET(DBUTTONL40),
  84.                             MS_NONE
  85.                         } ;
  86. static DBUTTONL40    d004d = {    MS_BTLEFTL40 | MS_EVMOSOFFL40 | MS_EVKEYONL40,
  87.                              190, 291, 251, 314, 7, 4, 8,
  88.                             MS_PANELL40 | MS_FRAMEL40,
  89.                             pitchUndo,
  90.                             0x0000
  91.                         } ;
  92.  
  93. /* pitchInfBtnId */
  94.  
  95. static MMIPACKET d005 = {    &pitchInfBtnId,
  96.                             &pitchDialogId,
  97.                             &MJ_DBUTTONL40,
  98.                             OFFSET(DBUTTONL40),
  99.                             MS_NONE
  100.                         } ;
  101. static DBUTTONL40    d005d = {    MS_BTLEFTL40 | MS_EVMOSOFFL40 | MS_EVKEYONL40,
  102.                              260, 291, 321, 314, 7, 4, 8,
  103.                             MS_PANELL40 | MS_FRAMEL40,
  104.                             pitchInf,
  105.                             0x0000
  106.                         } ;
  107.  
  108. /* pitchCanBtnId */
  109.  
  110. static MMIPACKET d006 = {    &pitchCanBtnId,
  111.                             &pitchDialogId,
  112.                             &MJ_DBUTTONL40,
  113.                             OFFSET(DBUTTONL40),
  114.                             MS_NONE
  115.                         } ;
  116. static DBUTTONL40    d006d = {    MS_BTLEFTL40 | MS_EVMOSOFFL40 | MS_EVKEYONL40,
  117.                              530, 291, 591, 314,10, 4, 8,
  118.                             MS_PANELL40 | MS_FRAMEL40,
  119.                             pitchCanchk,
  120.                             0x0000
  121.                         } ;
  122.  
  123. /* pitchMesId[0] */
  124.  
  125. static MMIPACKET d007 = {    &pitchMesId[0],
  126.                             &pitchDialogId,
  127.                             &MJ_MSGL40,
  128.                             OFFSET(MSGL40),
  129.                             MS_NONE
  130.                         } ;
  131. static MSGL40    d007d =     {    MS_CENTERL40 | MS_DSPONLYL40,
  132.                               60, 294, 103, 311, 8,15, 8,
  133.                             MS_NONEL40,
  134.                             "実  行",
  135.                                1,  12,  12,
  136.                             MS_NONEL40,
  137.                                0,   0
  138.                         } ;
  139.  
  140. /* pitchMesId[1] */
  141.  
  142. static MMIPACKET d008 = {    &pitchMesId[1],
  143.                             &pitchDialogId,
  144.                             &MJ_MSGL40,
  145.                             OFFSET(MSGL40),
  146.                             MS_NONE
  147.                         } ;
  148. static MSGL40    d008d =     {    MS_CENTERL40 | MS_DSPONLYL40,
  149.                              128, 294, 174, 311, 8,15, 8,
  150.                             MS_NONEL40,
  151.                             "再  生",
  152.                                1,  12,  12,
  153.                             MS_NONEL40,
  154.                                0,   0
  155.                         } ;
  156.  
  157. /* pitchMesId[2] */
  158.  
  159. static MMIPACKET d009 = {    &pitchMesId[2],
  160.                             &pitchDialogId,
  161.                             &MJ_MSGL40,
  162.                             OFFSET(MSGL40),
  163.                             MS_NONE
  164.                         } ;
  165. static MSGL40    d009d =     {    MS_CENTERL40 | MS_DSPONLYL40,
  166.                              196, 294, 247, 311, 8,15, 8,
  167.                             MS_NONEL40,
  168.                             "アンドゥ",
  169.                                1,  12,  12,
  170.                             MS_NONEL40,
  171.                                0,   0
  172.                         } ;
  173.  
  174. /* pitchMesId[3] */
  175.  
  176. static MMIPACKET d010 = {    &pitchMesId[3],
  177.                             &pitchDialogId,
  178.                             &MJ_MSGL40,
  179.                             OFFSET(MSGL40),
  180.                             MS_NONE
  181.                         } ;
  182. static MSGL40    d010d =     {    MS_CENTERL40 | MS_DSPONLYL40,
  183.                              265, 294, 316, 311, 8,15, 8,
  184.                             MS_NONEL40,
  185.                             "情  報",
  186.                                1,  12,  12,
  187.                             MS_NONEL40,
  188.                                0,   0
  189.                         } ;
  190.  
  191. /* pitchMesId[4] */
  192.  
  193. static MMIPACKET d011 = {    &pitchMesId[4],
  194.                             &pitchDialogId,
  195.                             &MJ_MSGL40,
  196.                             OFFSET(MSGL40),
  197.                             MS_NONE
  198.                         } ;
  199. static MSGL40    d011d =     {    MS_CENTERL40 | MS_DSPONLYL40,
  200.                              538, 294, 584, 311, 8,15, 8,
  201.                             MS_NONEL40,
  202.                             "取  消",
  203.                                1,  12,  12,
  204.                             MS_NONEL40,
  205.                                0,   0
  206.                         } ;
  207.  
  208. /* pitchMesId[5] */
  209.  
  210. static MMIPACKET d012 = {    &pitchMesId[5],
  211.                             &pitchDialogId,
  212.                             &MJ_MSGL40,
  213.                             OFFSET(MSGL40),
  214.                             MS_NONE
  215.                         } ;
  216. static MSGL40    d012d =     {    MS_LEFTL40 | MS_DSPONLYL40,
  217.                               53, 163, 173, 181, 8,15, 8,
  218.                             MS_NONEL40,
  219.                             "ピッチコントロール",
  220.                                1,  12,  12,
  221.                             MS_BOLDL40,
  222.                                0,   0
  223.                         } ;
  224.  
  225. /* pitchSubDialogId */
  226.  
  227. static MMIPACKET d013 = {    &pitchSubDialogId,
  228.                             &pitchDialogId,
  229.                             &MJ_DIALOGL40,
  230.                             OFFSET(DIALOGL40),
  231.                             MS_NONE
  232.                         } ;
  233. static DIALOGL40    d013d = {    MS_BTLEFTL40 | MS_EVMOSONL40 | MS_FIXEDL40,
  234.                               50, 183, 591, 284, 8, 4, 8,
  235.                             MS_DFRAMEL40 | MS_FRAMEL40,
  236.                             NULL,   0,   0
  237.                         } ;
  238.  
  239. /* pitchMulVolumeId */
  240.  
  241. static MMIPACKET d014 = {    &pitchMulVolumeId,
  242.                             &pitchSubDialogId,
  243.                             &MJ_SCRLL40,
  244.                             OFFSET(SCRLL40),
  245.                             MS_NONE
  246.                         } ;
  247. static SCRLL40    d014d =     {    MS_BTLEFTL40 | MS_REPEATL40 | MS_EVMOSONL40 | MS_HORIL40,
  248.                               72, 248, 503, 263, 8, 4, 7,
  249.                             MS_PANELL40 | MS_FRAMEL40,
  250.                             pitchMulSet,
  251.                               30,-160, 160,   1,   8,
  252.                              265, 266
  253.                         } ;
  254.  
  255. /* pitchMulNumId */
  256.  
  257. static MMIPACKET d015 = {    &pitchMulNumId,
  258.                             &pitchSubDialogId,
  259.                             &MJ_NUMBOXL40,
  260.                             OFFSET(NUMBOXL40),
  261.                             MS_NONE
  262.                         } ;
  263. static NUMBOXL40    d015d =     {    MS_BTLEFTL40 | MS_REPEATL40 | MS_EVMOSONL40 | MS_EVKEYONL40 | MS_RIGHTL40,
  264.                              519, 244, 574, 267, 8, 4, 8,
  265.                             MS_PANELL40 | MS_DFRAMEL40 | MS_FRAMEL40,
  266.                             pitchMulSet,
  267.                                1,  12,  12,
  268.                             MS_NONEL40,
  269.                                0,   0,
  270.                               30,-160, 160,   1,   0,
  271.                              263, 264
  272.                         } ;
  273.  
  274. /* pitchMesId[6] */
  275.  
  276. static MMIPACKET d016 = {    &pitchMesId[6],
  277.                             &pitchSubDialogId,
  278.                             &MJ_MSGL40,
  279.                             OFFSET(MSGL40),
  280.                             MS_NONE
  281.                         } ;
  282. static MSGL40    d016d =     {    MS_CENTERL40 | MS_DSPONLYL40,
  283.                              251, 190, 300, 207, 0,15, 8,
  284.                             MS_NONEL40,
  285.                             "音  程",
  286.                                1,  12,  12,
  287.                             MS_BOLDL40,
  288.                                0,   0
  289.                         } ;
  290.  
  291. /* pitchMesId[7] */
  292.  
  293. static MMIPACKET d017 = {    &pitchMesId[7],
  294.                             &pitchSubDialogId,
  295.                             &MJ_MSGL40,
  296.                             OFFSET(MSGL40),
  297.                             MS_NONE
  298.                         } ;
  299. static MSGL40    d017d =     {    MS_CENTERL40 | MS_DSPONLYL40,
  300.                              299, 190, 380, 207, 0,15, 8,
  301.                             MS_NONEL40,
  302.                             "(100 = 半音)",
  303.                                1,  12,  12,
  304.                             MS_NONEL40,
  305.                                0,   0
  306.                         } ;
  307.  
  308. /* pitchMesId[8] */
  309.  
  310. static MMIPACKET d018 = {    &pitchMesId[8],
  311.                             &pitchSubDialogId,
  312.                             &MJ_MSGL40,
  313.                             OFFSET(MSGL40),
  314.                             MS_NONE
  315.                         } ;
  316. static MSGL40    d018d =     {    MS_CENTERL40 | MS_DSPONLYL40,
  317.                              123, 212, 160, 226, 0,15, 8,
  318.                             MS_NONEL40,
  319.                             "-1200",
  320.                                1,  12,  12,
  321.                             MS_NONEL40,
  322.                                0,   0
  323.                         } ;
  324.  
  325. /* pitchMesId[9] */
  326.  
  327. static MMIPACKET d019 = {    &pitchMesId[9],
  328.                             &pitchSubDialogId,
  329.                             &MJ_MSGL40,
  330.                             OFFSET(MSGL40),
  331.                             MS_NONE
  332.                         } ;
  333. static MSGL40    d019d =     {    MS_CENTERL40 | MS_DSPONLYL40,
  334.                              196, 212, 233, 226, 0,15, 8,
  335.                             MS_NONEL40,
  336.                             "-600",
  337.                                1,  12,  12,
  338.                             MS_NONEL40,
  339.                                0,   0
  340.                         } ;
  341.  
  342. /* pitchMesId[10] */
  343.  
  344. static MMIPACKET d020 = {    &pitchMesId[10],
  345.                             &pitchSubDialogId,
  346.                             &MJ_MSGL40,
  347.                             OFFSET(MSGL40),
  348.                             MS_NONE
  349.                         } ;
  350. static MSGL40    d020d =     {    MS_CENTERL40 | MS_DSPONLYL40,
  351.                              280, 212, 298, 226, 0,15, 8,
  352.                             MS_NONEL40,
  353.                             "0",
  354.                                1,  12,  12,
  355.                             MS_NONEL40,
  356.                                0,   0
  357.                         } ;
  358.  
  359. /* pitchMesId[11] */
  360.  
  361. static MMIPACKET d021 = {    &pitchMesId[11],
  362.                             &pitchSubDialogId,
  363.                             &MJ_MSGL40,
  364.                             OFFSET(MSGL40),
  365.                             MS_NONE
  366.                         } ;
  367. static MSGL40    d021d =     {    MS_CENTERL40 | MS_DSPONLYL40,
  368.                              348, 212, 375, 226, 0,15, 8,
  369.                             MS_NONEL40,
  370.                             "600",
  371.                                1,  12,  12,
  372.                             MS_NONEL40,
  373.                                0,   0
  374.                         } ;
  375.  
  376. /* pitchMesId[12] */
  377.  
  378. static MMIPACKET d022 = {    &pitchMesId[12],
  379.                             &pitchSubDialogId,
  380.                             &MJ_MSGL40,
  381.                             OFFSET(MSGL40),
  382.                             MS_NONE
  383.                         } ;
  384. static MSGL40    d022d =     {    MS_CENTERL40 | MS_DSPONLYL40,
  385.                              419, 212, 446, 226, 0,15, 8,
  386.                             MS_NONEL40,
  387.                             "1200",
  388.                                1,  12,  12,
  389.                             MS_NONEL40,
  390.                                0,   0
  391.                         } ;
  392.  
  393. /* pitchMesId[13] */
  394.  
  395. static MMIPACKET d023 = {    &pitchMesId[13],
  396.                             &pitchSubDialogId,
  397.                             &MJ_MSGL40,
  398.                             OFFSET(MSGL40),
  399.                             MS_NONE
  400.                         } ;
  401. static MSGL40    d023d =     {    MS_LEFTL40 | MS_DSPONLYL40,
  402.                               94, 234, 293, 248, 0,15, 8,
  403.                             MS_NONEL40,
  404.                             "| | | | | | | | | | | | | | | |",
  405.                                1,  12,  12,
  406.                             MS_NONEL40,
  407.                                0,   0
  408.                         } ;
  409.  
  410. /* pitchMesId[14] */
  411.  
  412. static MMIPACKET d024 = {    &pitchMesId[14],
  413.                             &pitchSubDialogId,
  414.                             &MJ_MSGL40,
  415.                             OFFSET(MSGL40),
  416.                             MS_NONE
  417.                         } ;
  418. static MSGL40    d024d =     {    MS_LEFTL40 | MS_DSPONLYL40,
  419.                              286, 234, 485, 248, 0,15, 8,
  420.                             MS_NONEL40,
  421.                             "| | | | | | | | | | | | | | | | |",
  422.                                1,  12,  12,
  423.                             MS_NONEL40,
  424.                                0,   0
  425.                         } ;
  426.  
  427. /* pitchMesId[15] */
  428.  
  429. static MMIPACKET d025 = {    &pitchMesId[15],
  430.                             &pitchSubDialogId,
  431.                             &MJ_MSGL40,
  432.                             OFFSET(MSGL40),
  433.                             MS_NONE
  434.                         } ;
  435. static MSGL40    d025d =     {    MS_LEFTL40 | MS_DSPONLYL40,
  436.                              142, 228, 160, 242, 0,15, 8,
  437.                             MS_NONEL40,
  438.                             "|",
  439.                                1,  12,  12,
  440.                             MS_NONEL40,
  441.                                0,   0
  442.                         } ;
  443.  
  444. /* pitchMesId[16] */
  445.  
  446. static MMIPACKET d026 = {    &pitchMesId[16],
  447.                             &pitchSubDialogId,
  448.                             &MJ_MSGL40,
  449.                             OFFSET(MSGL40),
  450.                             MS_NONE
  451.                         } ;
  452. static MSGL40    d026d =     {    MS_LEFTL40 | MS_DSPONLYL40,
  453.                              214, 228, 232, 242, 0,15, 8,
  454.                             MS_NONEL40,
  455.                             "|",
  456.                                1,  12,  12,
  457.                             MS_NONEL40,
  458.                                0,   0
  459.                         } ;
  460.  
  461. /* pitchMesId[17] */
  462.  
  463. static MMIPACKET d027 = {    &pitchMesId[17],
  464.                             &pitchSubDialogId,
  465.                             &MJ_MSGL40,
  466.                             OFFSET(MSGL40),
  467.                             MS_NONE
  468.                         } ;
  469. static MSGL40    d027d =     {    MS_LEFTL40 | MS_DSPONLYL40,
  470.                              286, 228, 305, 242, 0,15, 8,
  471.                             MS_NONEL40,
  472.                             "|",
  473.                                1,  12,  12,
  474.                             MS_NONEL40,
  475.                                0,   0
  476.                         } ;
  477.  
  478. /* pitchMesId[18] */
  479.  
  480. static MMIPACKET d028 = {    &pitchMesId[18],
  481.                             &pitchSubDialogId,
  482.                             &MJ_MSGL40,
  483.                             OFFSET(MSGL40),
  484.                             MS_NONE
  485.                         } ;
  486. static MSGL40    d028d =     {    MS_LEFTL40 | MS_DSPONLYL40,
  487.                              358, 228, 377, 242, 0,15, 8,
  488.                             MS_NONEL40,
  489.                             "|",
  490.                                1,  12,  12,
  491.                             MS_NONEL40,
  492.                                0,   0
  493.                         } ;
  494.  
  495. /* pitchMesId[19] */
  496.  
  497. static MMIPACKET d029 = {    &pitchMesId[19],
  498.                             &pitchSubDialogId,
  499.                             &MJ_MSGL40,
  500.                             OFFSET(MSGL40),
  501.                             MS_NONE
  502.                         } ;
  503. static MSGL40    d029d =     {    MS_LEFTL40 | MS_DSPONLYL40,
  504.                              430, 228, 449, 242, 0,15, 8,
  505.                             MS_NONEL40,
  506.                             "|",
  507.                                1,  12,  12,
  508.                             MS_NONEL40,
  509.                                0,   0
  510.                         } ;
  511.  
  512.